﻿using System;
using System.Collections.Generic;
using System.Web;
using Utils;
using System.Data;

/// <summary>
///OrderBBasePage 的摘要说明
/// </summary>
public class OrderBBasePage : BBasepage
{
    // Methods
    public string GetOrderExpress(object order_user_Category)
    {
        DataRowView view = (DataRowView)order_user_Category;
        string str = "快递";
        if (view["express"].ToString() == "N")
        {
            return "优惠券";
        }
        if (view["state"].ToString() == "pay")
        {
            if (view["Category_name"].ToString() != string.Empty)
            {
                str = str + "<br>" + view["Category_name"];
            }
            if (view["express_no"].ToString() != string.Empty)
            {
                str = str + "<br>" + view["express_no"];
            }
            if (view["express_xx"].ToString() != string.Empty)
            {
                str = str + "<br>" + view["express_xx"];
            }
        }
        return str;
    }

    protected override void OnLoad(EventArgs e)
    {
        base.OnLoad(e);
        if (!(base.CheckUserAuth("order") || base.IsSupper))
        {
            this.SetError("没有权限进行此操作");
            base.SetRefer();
            base.Response.Redirect(WebSiteHelper.GetReferUrl());
            base.Response.End();
        }
    }
}

